import { io } from "socket.io-client"
import utils from "@/utils/utils"

const socket = io(utils.socketUrl, {
    autoConnect: false, // 取消自动连接
    query: {},
    upgrade: false, 
    reconnection: true,
    transports: ['websocket', 'polling'],
    extraHeaders: { 'Access-Control-Allow-Origin': '*' }
})


export default socket